import { createRouter, createWebHashHistory } from 'vue-router'

const routes = [
  {
    path: '/',
    component: () => import(/* webpackChunkName: "home" */ '../App.vue'),
    children: [
      {
        path: 'test',
        component: () => import(/* webpackChunkName: "store" */ '../views/Test.vue')
      },
      {
        path: 'father',
        component: () => import(/* webpackChunkName: "father" */ '../views/Father.vue')
      },
      {
        path: 'store',
        component: () => import(/* webpackChunkName: "store" */ '../views/Store.vue')
      },
      {
        path: 'getters',
        component: () => import(/* webpackChunkName: "getters" */ '../views/Getters.vue')
      },
      {
        path: 'mutation',
        component: () => import(/* webpackChunkName: "mutation" */ '../views/Mutation.vue')
      },
      {
        path: 'actions',
        component: () => import(/* webpackChunkName: "actions" */ '../views/Actions.vue')
      },
      {
        path: 'moduleA',
        component: () => import(/* webpackChunkName: "moduleA" */ '../views/ModuleA.vue')
      },
      {
        path: 'moduleA2',
        component: () => import(/* webpackChunkName: "moduleA2" */ '../views/ModuleA2.vue')
      },
      {
        path: 'compositionAPI',
        component: () => import(/* webpackChunkName: "compositionAPI" */ '../views/CompositionAPI.vue')
      }
    ]
  }
]

const router = createRouter({
  history: createWebHashHistory(),
  routes
})

export default router